/** \file    binstream.h
  * \brief   Serialization of typelib objects in binary stream.
  * \date    2003
  * \author  Fedor Chelnokov
  * \version $Header: /home/cscom1r4/cvsroot/cs/include/typelib/binstream.h,v 1.1 2004/09/21 18:21:30 cscom1r4 Exp $
  */

#ifndef _typelib_binstream_h_
#define _typelib_binstream_h_

#include <xtd/bistream>
#include <xtd/bostream>

namespace types {
	//template <class T> struct basic_affine;
	template <class T> class point;
	//template <class T> class smooth_point;
	//template <class T> class extent;
	//template <class T> class rect;
}
using namespace types;

namespace xtd {

template <class T>
inline bistream & operator >> (bistream & in, point<T> & p)
{
	return in >> p.x >> p.y;
}

template <class T>
inline bostream & operator << (bostream & out, const point<T> & p)
{
	return out << p.x << p.y;
}

} //namespace xtd

#endif //_typelib_binstream_h_
